package com.shanpin.shebao.security.privilege.vo;

import com.shanpin.shebao.security.privilege.dto.TSysUser;

public class UserForPrivilege {

	/**  */
	private int id;
	/** 帐号 */
	private String username;
	/** 姓名或昵称 */
	private String nickname;
	/** 是否可用 */
	private boolean enabled;
	/** 关联的渠道号 */
	private int pay_channel;
	/** 2专员 */
	private int user_type;
	/** 权限配置类型，两种：roleId > 0,是通过角色配置的。roleId==0,是自定权限。*/
	private int roleId;
	
	public UserForPrivilege(TSysUser user, int roleId) {
		this.id = user.getId();
		this.username = user.getUsername();
		this.nickname = user.getNickname();
		this.enabled = user.isEnabled();
		this.pay_channel = user.getPay_channel();
		this.user_type = user.getUser_type();
		this.roleId = roleId;
	}

	public int getId() {
		return id;
	}

	public void setId(int id) {
		this.id = id;
	}

	public String getUsername() {
		return username;
	}

	public void setUsername(String username) {
		this.username = username;
	}

	public String getNickname() {
		return nickname;
	}

	public void setNickname(String nickname) {
		this.nickname = nickname;
	}

	public boolean isEnabled() {
		return enabled;
	}

	public void setEnabled(boolean enabled) {
		this.enabled = enabled;
	}

	public int getPay_channel() {
		return pay_channel;
	}

	public void setPay_channel(int pay_channel) {
		this.pay_channel = pay_channel;
	}

	public int getUser_type() {
		return user_type;
	}

	public void setUser_type(int user_type) {
		this.user_type = user_type;
	}

	public int getRoleId() {
		return roleId;
	}

	public void setRoleId(int roleId) {
		this.roleId = roleId;
	}
}
